package com.qcit.work

import android.graphics.Bitmap
import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle
import android.widget.Toast
import com.qcit.annotation.AParameter
import com.qcit.annotation.AParameterBind
import com.qcit.annotation.ARouter
import com.qcit.api.ARouterManager
import com.qcit.api.LoginIntercept
import com.qcit.common.interfaces.IUser
import com.qcit.common.utils.UserUtil

@ARouter("/work/TestActivity2")
class TestActivity : AppCompatActivity() {
//    @AParameter
//    var title = "张三"
//    @AParameter
//    var MSSS = ""
//    @AParameter
//    var woMane = 0
//    @AParameter
//    var SPT_text = ""
//    @AParameter
//    var addText = ""
//    @AParameter
//    var fsf_Ssdad = ""
//    @AParameter
//    var isCheck = false
//    @AParameter
//    var bundle:Bundle? = null
//    @AParameter("/user/getUserInfo")
//    lateinit var   iUser: IUser
    //var loginClass:Class<*> = UserUtil::class.java //登录路径
    @AParameterBind
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
//        setContentView(R.layout.activity_test)
//        Toast.makeText(this, iUser.getString(), Toast.LENGTH_SHORT).show()
      //  var name = loginClass.name

    }
    fun test(){
        var __utils = Class.forName("Ljava.lang.XXXXXXX").newInstance() as LoginIntercept
        if (__utils.isLogin()){
            ARouterManager.instance.build("/user/Login").navigation(this)
            return
        }
    }
}